set fileformat=unix

mkdir $HOME/.vim_old

if [ -f "$HOME/.vimrc" ];then
    echo "Your '$HOME/.vimrc' is saved as '$HOME/.vimrc.bak'"
    cp $HOME/.vimrc $HOME/.vim_old/.vimrc.bak
    rm $HOME/.vimrc
fi

echo "Get new '$HOME/.vimrc'"
cp .vimrc $HOME/.vimrc

if [ -f "$HOME/.vim" ];then
    echo "Your '$HOME/.vim' is saved as '$HOME/.vim.bak'"
    cp $HOME/.vim $HOME/.vim_old/.vim.bak
    rm $HOME/.vim -rf
fi

mv .vim $HOME/.vim


echo "Get $HOME/.vim/autoload/plug.vim"
mv plug.vim $HOME/.vim/autoload/plug.vim


echo "Get new '$HOME/.vim'"
mv .vim $HOME/.vim

